package org.ycx.upms.service;

import org.ycx.common.base.BaseService;
import org.ycx.upms.dao.model.SecGroup;
import org.ycx.upms.dao.model.SecGroupUserExample;
import org.ycx.upms.dao.model.SecUser;
import org.ycx.upms.dao.model.SecUserExample;

import java.util.List;

/**
* SecUserService接口
* Created by yang on 2017/6/26.
*/
public interface ISecUserService extends BaseService<SecUser, SecUserExample> {

    SecUser findUserInfo(String loginName);

    List<SecUser> selectUserByRoleId(Integer rid, int offset, int limit);

    long countUserByRoleId(Integer rid);

    List<Integer> selectRidsByUser(Integer uid);

    int updateUserRole(Integer uid, Integer[] rids);

    List<SecGroup> findUserGroups(SecGroupUserExample sgu);

    List<Integer> findUserGid(Integer uid);

    int updateUserGroups(Integer uid, Integer[] gids);
}